import request from '@/utils/request'

// 查询视频列表
export function loadMedia(data) {
    return request({
        url: '/app/ap_video/load_video',
        method: 'post',
        data: data
    })
}

// 查询视频详情
export function findDetial(data) {
    return request({
        url: '/app/ap_video/find',
        method: 'post',
        data: data
    })
}

// 查询视频弹幕
export function findDanmaku(data) {
    return request({
        url: '/app/ap_video_danmaku/load',
        method: 'post',
        data: data
    })
}

// 保存视频弹幕
export function saveDanmaku(data) {
    return request({
        url: '/app/ap_video_danmaku/save',
        method: 'post',
        data: data
    })
}

// 保存播放记录
export function saveOrUpdateHistory(data) {
    return request({
        url: '/app/ap_video_history/save_history',
        method: 'post',
        data: data
    })
}

// 查询播放记录
export function loadHistory(data) {
    return request({
        url: '/app/ap_video_history/load_history',
        method: 'post',
        data: data
    })
}

// 获取播放页视频列表
export function findVideoDetailList(data) {
    return request({
        url: '/app/ap_video/find_video_detail_info',
        method: 'post',
        data: data
    })
}

// 通过类型查询视频列表
export function loadMediaByType(data) {
    return request({
        url: '/media/ad_media_type/load_media_by_type',
        method: 'post',
        data: data
    })
}

// 通过标签查询视频列表
export function loadMediaByTag(data) {
    return request({
        url: '/media/ad_tag/load_media_by_tag',
        method: 'post',
        data: data
    })
}